﻿// ------------------------------------------------------------------------------
//  © 2008 OpenUpon™.  All rights reserved.
// ------------------------------------------------------------------------------
using Castle.ActiveRecord;

namespace CastUpon.Entities {
	[ActiveRecord]
	public class User : ActiveRecordBase<User> {
		private int id;
		private string password;
		private string username;

		[PrimaryKey]
		public int Id {
			get { return this.id; }
			set { this.id = value; }
		}

		[Property]
		public string Username {
			get { return this.username; }
			set { this.username = value; }
		}

		[Property]
		public string Password {
			get { return this.password; }
			set { this.password = value; }
		}

		public static int GetUsersCount() {
			return Count();
		}
	}
}